import { ElLoading } from "element-plus";
var l: any;
const loading = {
  show: function (message?: string): void {
    l = ElLoading.service({
      lock: true,
      text: message || "加载中...",
      background: "rgba(0, 0, 0, 0.7)",
    });
  },
  hide: function (): void {
    l?.close();
  },
};

export default loading;
